<template>
      <el-container direction="vertical" style="height: 100%">
          <el-header style="height: 70px">
              <header-bar/>
          </el-header>
          <el-container style="margin-top: 10px;height: 100%">
              <el-aside width="250px" style="height: 100%">
                <el-scrollbar style="height: 99%;">
                  <side-bar/>
                </el-scrollbar>
              </el-aside>
              <el-main>
                <el-scrollbar style="height: 99%;">
                  <div style="padding: 15px;box-shadow: 0 2px 4px rgba(0, 0, 0, .12), 0 0 6px rgba(0, 0, 0, .04);background-color: white;height: 100%">
                    <router-view/>
                  </div>
                </el-scrollbar>
              </el-main>
          </el-container>
      </el-container>
</template>
<script type="text/ecmascript-6">
    import headerBar from './HeaderBar'//顶部
    import sideBar from './SideBar'//侧边
    export default {
        name:'home',
        components: {
            headerBar,
            sideBar
        },
        data() {
            return {
                activeIndex: '1',
                activeIndex2: '1',
                isCollapse: true,
                squareUrl: "https://cube.elemecdn.com/9/c2/f0ee8a3c7c9638a54940382568c9dpng.png",
                drawer: false
            }
        },
        methods: {
            handleSelect(key, keyPath) {
                console.log(key, keyPath);
            },

            handleOpen(key, keyPath) {
                console.log(key, keyPath);
            },
            handleClose(key, keyPath) {
                console.log(key, keyPath);
            }
        }
    }
</script>
<style>
  .bg-purple-dark {
    background: #ffebf0;
  }

  .el-header, .el-footer {
    background-color: #FFF;
    color: #333;
    padding: 0;
    line-height: 80px;
  }

  .el-aside {
    background-color: #FFF;
    color: #333;
  }

  .el-main {
    background-color: #E9EEF3;
    color: #333;


  }

  body,html{
    height: 100%;
  }

  body > .el-container {
    margin-bottom: 40px;
  }
  .el-scrollbar__view{
    height: 100%;
  }

</style>
